<?php

namespace app\validate;

use think\Validate;

class CompanyValidate extends Validate
{
    protected $rule = [
        'id' => 'require',
        'name' => 'require',
        'status' => 'require|in:100,200',
    ];

    protected $message = [
        'name.require' => '请输入企业名称',
        'status.require' => '请选择状态',
        'id.require' => '请选择企业',
    ];

    protected $scene = [
        'add' => ['name', 'status'],
        'edit' => ['id', 'name', 'status'],
        'del' => ['id']
    ];


}